<template>
    <div>
        <van-dropdown-menu>
            <slot></slot>
            <template v-if="dataSource.length>0">
                <van-dropdown-item :options="item.data" @change="change($event,item)" :title="item.title" v-for="(item,index) in dataSource" :key="index"></van-dropdown-item>
            </template>
        </van-dropdown-menu>
    </div>
</template>
<script>
export default {
    name:"eagle-dropdown-menu",
    props:{
        dataSource:{
            type: Array,
            default: () => [],
        },
        isCustom:{
            type:Boolean,
            default:false,
        },
        conditions: {
            type: Object,
            default: () => {
                return {};
            },
        },
    },
    data(){
        return {
            
        }
    },
    watch:{
        
    },
    created(){
        
    },
    methods:{
        change(val,item){
            this.conditions[item.name] = {
                value:val,
                operate:"=",
            }
        }
    },
}
</script>
<style lang="less" scoped>

</style>